package com.zpark.controller;

import com.zpark.entity.patients.TcmPrescription;
import com.zpark.service.TcmPrescriptionService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

import java.util.List;

@RestController
@RequestMapping("/api/tcm-prescriptions")
public class TcmPrescriptionController {
    
    @Autowired
    private TcmPrescriptionService tcmPrescriptionService;
    
    @GetMapping
    public List<TcmPrescription> getAllTcmPrescriptions() {
        return tcmPrescriptionService.list();
    }
}